package com.gupaoedu.concurrent.thread.example.processor;

import com.gupaoedu.concurrent.thread.example.FlightDetail;
import com.gupaoedu.concurrent.thread.example.HotelDetail;
import com.gupaoedu.concurrent.thread.example.Itinerary;

import java.util.List;

/**
 * 2019/5/12
 * created by chenpp
 */
public class HotelProcessor implements  Processor {
    @Override
    public List<Itinerary> handler(List<Itinerary> itineraries) {
        for(Itinerary itinerary:itineraries){
            HotelDetail detail = new HotelDetail();
            detail.setScheduleType(itinerary.getSchedultType());
            detail.setHotelName("酒店");
            detail.setHotelAddress("上海市");
            itinerary.setHotelDetail(detail);
        }
        return itineraries;
    }
}
